<template>
  <ex_select_auto
    :value="value"
    url="/oms-api/tickets/OmsBaseTicketsCatalogRpc/getTicketsCatalogsByName.json"
    filterable
    remote
    :disabled="disabled"
    remoteQuery="selectValue"
    :urlParams="{ needRootCatalog: needRootCatalog, type: type, rootId: rootId }"
    :dependentId="type"
    :reserve-keyword="true"
    placeholder="选择工单目录"
    :option="option"
    v-bind="$attrs"
    v-on="$listeners"
  />
</template>

<script>
export default {
  name: "workorder_catalogue_select",
  props: {
    value: null,
    disabled: {
      type: Boolean,
      default: false,
    },
    needRootCatalog: {
      type: String,
      default: "N",
    },
    type: null,
    rootId: null,
    option: {
      type: Object,
      default: () => {
        return { label: "name", value: "id" };
      },
    },
  },
  methods: {},
};
</script>
